#include <stdio.h>
#include <string.h>
#include <malloc.h>

int main( void )
{
	char *p = NULL;

	p =( char * )malloc( 512 );
	if ( NULL == p )
		return -1;

	strcpy( p, "1234567890" );

	printf( "p = [ %s ]\n", p );

	free( p );
	p = NULL;

	if ( NULL == p)
		return -1;

	strcpy( p, "hello" );

	printf( "p = [ %s ]\n", p );

	return 1;	
	
}
